<?php

namespace App\Exceptions;

define('DATA_NOT_FOUND', ['errcode' => 'ERR001001', 'errmsg' => '数据不存在']);

class ApiException extends BizException
{
    public $rescode;

    public $resmsg;

    function __construct($err)
    {
        $this->rescode = $err['errcode'];
        $this->resmsg = $err['errmsg'];
        parent::__construct($this->rescode, $this->resmsg);
    }
}